#ifndef __ZVECTOR_H__
#define __ZVECTOR_H__

// the class name with small letter, is lib src files
// the class name with big letter, is proj src files
typedef struct zvector {

	// the inner prop, suggest don't use directly
	void ** m_List;

	// the vector's elements count
	int m_Count;

	// capacity of vector
	int m_Capacity;

} zvector;

// create vector with originCapacity, 
// the originCapacity's value must more than or equal to zero
// the initalize m_List's memory size is the nearest number who is greater than or equal to 2's pow
//		such as: oroginCapacity = 0, m_List's size = 2 * (sizeof(void *))
//		such as: oroginCapacity = 4, m_List's size = 4 * (sizeof(void *))
//		such as: oroginCapacity = 9, m_List's size = 16 * (sizeof(void *))
//      and so on
int zvector_create(zvector ** obj, int originCapacity);

// add one item's ref(address) to the zvector's last
int zvector_add(zvector * obj, void * item);

// destroy the obj pointing memory, and set *obj to NULL
int zvector_destroy(zvector ** obj);

#endif